Optimal. Leaf size=81 \[ -\frac {a A \tanh ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a+b x^2}}\right )}{2 b^{3/2}}-\frac {\sqrt {a+b x^2} (4 a B-3 A b x)}{6 b^2}+\frac {B x^2 \sqrt {a+b x^2}}{3 b} \]
________________________________________________________________________________________
Rubi [A] time = 0.04, antiderivative size = 81, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {833, 780, 217, 206} \begin {gather*} -\frac {\sqrt {a+b x^2} (4 a B-3 A b x)}{6 b^2}-\frac {a A \tanh ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a+b x^2}}\right )}{2 b^{3/2}}+\frac {B x^2 \sqrt {a+b x^2}}{3 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rule 217
Rule 780
Rule 833
Rubi steps
\begin {align*} \int \frac {x^2 (A+B x)}{\sqrt {a+b x^2}} \, dx &=\frac {B x^2 \sqrt {a+b x^2}}{3 b}+\frac {\int \frac {x (-2 a B+3 A b x)}{\sqrt {a+b x^2}} \, dx}{3 b}\\ &=\frac {B x^2 \sqrt {a+b x^2}}{3 b}-\frac {(4 a B-3 A b x) \sqrt {a+b x^2}}{6 b^2}-\frac {(a A) \int \frac {1}{\sqrt {a+b x^2}} \, dx}{2 b}\\ &=\frac {B x^2 \sqrt {a+b x^2}}{3 b}-\frac {(4 a B-3 A b x) \sqrt {a+b x^2}}{6 b^2}-\frac {(a A) \operatorname {Subst}\left (\int \frac {1}{1-b x^2} \, dx,x,\frac {x}{\sqrt {a+b x^2}}\right )}{2 b}\\ &=\frac {B x^2 \sqrt {a+b x^2}}{3 b}-\frac {(4 a B-3 A b x) \sqrt {a+b x^2}}{6 b^2}-\frac {a A \tanh ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a+b x^2}}\right )}{2 b^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.06, size = 64, normalized size = 0.79 \begin {gather*} \frac {\sqrt {a+b x^2} (b x (3 A+2 B x)-4 a B)-3 a A \sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a+b x^2}}\right )}{6 b^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [A] time = 0.29, size = 68, normalized size = 0.84 \begin {gather*} \frac {a A \log \left (\sqrt {a+b x^2}-\sqrt {b} x\right )}{2 b^{3/2}}+\frac {\sqrt {a+b x^2} \left (-4 a B+3 A b x+2 b B x^2\right )}{6 b^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.90, size = 127, normalized size = 1.57 \begin {gather*} \left [\frac {3 \, A a \sqrt {b} \log \left (-2 \, b x^{2} + 2 \, \sqrt {b x^{2} + a} \sqrt {b} x - a\right ) + 2 \, {\left (2 \, B b x^{2} + 3 \, A b x - 4 \, B a\right )} \sqrt {b x^{2} + a}}{12 \, b^{2}}, \frac {3 \, A a \sqrt {-b} \arctan \left (\frac {\sqrt {-b} x}{\sqrt {b x^{2} + a}}\right ) + {\left (2 \, B b x^{2} + 3 \, A b x - 4 \, B a\right )} \sqrt {b x^{2} + a}}{6 \, b^{2}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.52, size = 61, normalized size = 0.75 \begin {gather*} \frac {1}{6} \, \sqrt {b x^{2} + a} {\left ({\left (\frac {2 \, B x}{b} + \frac {3 \, A}{b}\right )} x - \frac {4 \, B a}{b^{2}}\right )} + \frac {A a \log \left ({\left | -\sqrt {b} x + \sqrt {b x^{2} + a} \right |}\right )}{2 \, b^{\frac {3}{2}}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.01, size = 75, normalized size = 0.93 \begin {gather*} \frac {\sqrt {b \,x^{2}+a}\, B \,x^{2}}{3 b}-\frac {A a \ln \left (\sqrt {b}\, x +\sqrt {b \,x^{2}+a}\right )}{2 b^{\frac {3}{2}}}+\frac {\sqrt {b \,x^{2}+a}\, A x}{2 b}-\frac {2 \sqrt {b \,x^{2}+a}\, B a}{3 b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 1.29, size = 67, normalized size = 0.83 \begin {gather*} \frac {\sqrt {b x^{2} + a} B x^{2}}{3 \, b} + \frac {\sqrt {b x^{2} + a} A x}{2 \, b} - \frac {A a \operatorname {arsinh}\left (\frac {b x}{\sqrt {a b}}\right )}{2 \, b^{\frac {3}{2}}} - \frac {2 \, \sqrt {b x^{2} + a} B a}{3 \, b^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.47, size = 93, normalized size = 1.15 \begin {gather*} \left \{\begin {array}{cl} \frac {3\,B\,x^4+4\,A\,x^3}{12\,\sqrt {a}} & \text {\ if\ \ }b=0\\ \frac {A\,x\,\sqrt {b\,x^2+a}}{2\,b}-\frac {A\,a\,\ln \left (2\,\sqrt {b}\,x+2\,\sqrt {b\,x^2+a}\right )}{2\,b^{3/2}}-\frac {B\,\sqrt {b\,x^2+a}\,\left (2\,a-b\,x^2\right )}{3\,b^2} & \text {\ if\ \ }b\neq 0 \end {array}\right . \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 6.23, size = 94, normalized size = 1.16 \begin {gather*} \frac {A \sqrt {a} x \sqrt {1 + \frac {b x^{2}}{a}}}{2 b} - \frac {A a \operatorname {asinh}{\left (\frac {\sqrt {b} x}{\sqrt {a}} \right )}}{2 b^{\frac {3}{2}}} + B \left (\begin {cases} - \frac {2 a \sqrt {a + b x^{2}}}{3 b^{2}} + \frac {x^{2} \sqrt {a + b x^{2}}}{3 b} & \text {for}\: b \neq 0 \\\frac {x^{4}}{4 \sqrt {a}} & \text {otherwise} \end {cases}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________